import request from "../utils/reuqest.js";

// 获取所有的角色
export const api_role_query = () => request.get("roles");


// 定义给角色分配权限的api
export const api_serRight = (data) => request.post(`roles/${data.roleId}/rights`, data);

// 删除指定角色的权限
export const api_delteRight = ({ roleId, rightId }) => request.delte(`roles/${roleId}/rights/${rightId}`)